<%= form_for(@falla_tecnica, :url=> technical_failures_path, :method=>'post', :html=>{:id=>"form_technical_failures"}) do |f| %>
	<h2>Registro de falla técnica</h2>
	<table>
	<tr><td><b>Marca:</b></td><td><%= text_field_tag "", @bus.fleet.marca, :class => "MiTextField1", :readonly => true %></td></tr>
	<tr><td><b>Modelo:</b></td><td><%= text_field_tag "", @bus.fleet.modelo, :class => "MiTextField1", :readonly => true %></td></tr>
	<tr><td><b>Placa:</b></td><td><%= text_field_tag "", @bus.placa, :class => "MiTextField1", :readonly => true %></td></tr>
	<tr><td><b>Ult. Rev. Técnica:</b></td><td><%= text_field_tag "", @bus.ultRevisionTecnica.in_time_zone("Lima").to_date.to_formatted_s(:long), :class => "MiTextField1", :readonly => true %></td></tr>
	</table>

	<%= field_set_tag text="Registro de falla tecnica", :class => "MiFieldSet1" do%>
		<div class="field">
		  <%= f.label "Criticidad" %><br />
		  <%= select_tag 'criticidad', "<option>BAJA</option><option>MEDIA</option><option>ALTA</option>".html_safe, :multiple => false %>
		</div>
		<div class="field">
		  <%= f.label "Fecha de la falla técnica" %><br />
		  <%= f.date_select :fechaFalla %>
		</div>
		<div class="field">
		  <%= f.label "Parte afectada" %><br />
		  <%= f.text_field :parteAfectada, :class => "MiTextField1" %>
		</div>
		<div class="field">
		  <%= f.label "Descripción de la falla" %><br />
		  <%= f.text_area :descripcion, :class => "MiTextField1" %>
		</div>
		<div class="field">
			<%= f.submit "Registrar", :class => "MiBoton1", :style => "margin-right: 5px; margin-bottom: 5px; padding-left: 0px; margin-top: 10px;" %>
		</div>
		<div class="field">
		  <%= hidden_field_tag 'codigoBus', @bus.id %>
		</div>
	<% end %>

<% end %>
